package com.whjfxx.terminal.biz.service;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import com.whjfxx.terminal.biz.param.OrgPageParam;
import com.whjfxx.terminal.biz.param.OrgParam;
import com.whjfxx.terminal.biz.param.OrgTreeParam;
import com.whjfxx.terminal.biz.param.SearchParam;
import com.whjfxx.terminal.biz.vo.OrgVo;
import com.whjfxx.terminal.commons.TreeVo;
import com.whjfxx.terminal.entity.SysOrganization;

import java.util.List;

public interface SysOrganizationService extends IService<SysOrganization> {

    /**
     * 分页查询列表
     * @param param
     * @return
     */
    Page<OrgVo> pageList(SearchParam<OrgPageParam> param);

    /**
     * insert
     * @param param
     */
    void insertSave(OrgParam param);

    /**
     * update
     * @param param
     */
    void updateSave(OrgParam param);

    /**
     * 停用
     * @param id
     */
    void disable(Long id);

    /**
     * 启用
     * @param id
     */
    void enable(Long id);

    /**
     * 根据id批量查询
     * @param ids
     * @return
     */
    List<SysOrganization> getByIds(List<Long> ids);

    List<TreeVo> tree(OrgTreeParam orgTreeParam);
}
